Qualcomm AI Engine Direct - heap profiling at runtime on target#19716
Qualcomm AI Engine Direct - heap profiling at runtime on target#19716jethroqti wants to merge 1 commit into
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/19716
Note: Links to docs will display an error until the docs builds have been completed. This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
@pytorchbot label "release notes: qualcomm" |
|
Can you rebase your PR please? |
|
@claude review this PR |
|
Claude finished @psiddh's task in 3m 29s —— View job Code Review: Qualcomm AI Engine Direct - Heap Profiling at Runtime on Target
SummaryThis PR adds DSP heap profiling for the QNN HTP backend at runtime. It captures heap usage at two checkpoints (before first context creation, after last context freed) and writes them to a file. The implementation uses static state to coordinate across multiple contexts. Issues & Suggestions1. Race condition:
|
Sure. |
Summary:
Heap profiling at runtime with HTP backend on Android platforms. DSP
heap profiling is available for QnnContext_createFromBinary use-cases.
It captures total DSP heap usage at two checkpoints:
- Before the first context is created (before_context_created)
- After the last context is freed (after_context_freed)
The difference between the two values represents heap consumed during
context execution. The value after freeing is typically equal to or
greater than before creation.
Test plan:
python backends/qualcomm/tests/test_qnn_delegate.py
TestQNNQuantizedUtils.test_qnn_backend_runtime_option_heap_profile -b
build-android -H ${HOST} -s ${SN} -m ${SOC_MODEL}
Note:
This test is expected to run on target device.
eff7a0f to
7a83ebe
Compare
|
|
@pytorchbot label "release notes: qualcomm" |
Qualcomm AI Engine Direct - heap profiling at runtime on target